package com.autumn.word;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;

import org.apache.poi.xwpf.usermodel.XWPFDocument;

/**
 * Word 解析
 * 
 * @author 老码农 2019-04-24 01:17:09
 */
public interface WorkEvaluate {

	/**
	 * 解析
	 * 
	 * @param sourceFile
	 *            源文件
	 * @return
	 */
	WorkWithOptional with(File sourceFile) throws FileNotFoundException;

	/**
	 * 解析
	 * 
	 * @param sourceFilePath
	 *            源文件路径
	 * @return
	 */
	WorkWithOptional with(String sourceFilePath) throws FileNotFoundException;

	/**
	 * 解析
	 * 
	 * @param sourceInputStream
	 *            源输入流
	 * @return
	 */
	WorkWithOptional with(InputStream sourceInputStream);

	/**
	 * 解析
	 * 
	 * @param sourceDocument
	 *            源文档
	 * @return
	 */
	WorkWithOptional with(XWPFDocument sourceDocument) throws IOException;

	/**
	 * 解析
	 * 
	 * @param sourceInputStream
	 *            源输入流
	 * @param closeStream
	 *            关闭流
	 * @return
	 */
	WorkWithOptional with(InputStream sourceInputStream, boolean closeStream);
}
